package com.gec.hawaste.mapper;

import com.gec.hawaste.entity.Waste;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author chenxys
 * @since 2022-07-01
 */
@Mapper
public interface WasteMapper extends BaseMapper<Waste> {
    @Select("SELECT * FROM waste,sys_office_waste " +
            "WHERE waste.id = sys_office_waste.waste_id " +
            "and sys_office_waste.office_id=#{officeId}")
    Waste findByOfficeId(@Param("officeId") Long officeId);
}
